<footer class="footer">
    {{ partial "footer/select-lang" . }}
    {{ partial "footer/links-social.html" . }}
    {{ partial "footer/go-to-top" . }}
    <hr />

    <div class="basicflex">
        {{ range $.Param "footerLinks" }}
            <a href="{{ .link }}" class="footer__link" target="_blank" rel="noreferrer">{{ .name }}</a>
        {{ end }}
    </div>

    <div class="footer__poweredby">
        {{ partial "footer/site-counter" . }}
        {{ if $.Site.Copyright }}        
            <p class="caption">
                {{ if $.Site.Params.copyrightOptions.enableCopyrightLink }}
                    {{ $leftString := replace (index (split $.Site.Copyright "{}") 0) "{year}" now.Year }}
                    {{ $rightString := replace (index (split $.Site.Copyright "{}") 1) "{year}" now.Year }}

                    {{ if and ($.Site.Params.copyrightOptions.copyrightLinkImage) ($.Site.Params.copyrightOptions.copyrightLinkText) }}
                        <a rel="license" href="{{ $.Site.Params.copyrightOptions.copyrightLink }}" class="footer__copyright--img"><img alt="{{ $.Site.Params.copyrightOptions.copyrightLinkText }}" style="border-width:0" src="{{ $.Site.Params.copyrightOptions.copyrightLinkImage }}"/></a>{{ $leftString | markdownify }}<a rel="license" href="{{ $.Site.Params.copyrightOptions.copyrightLink }}">{{ $.Site.Params.copyrightOptions.copyrightLinkText }}</a>{{ $rightString | markdownify }}
                    {{ else }}
                        {{ $leftString | markdownify }}<a rel="license" href="{{ $.Site.Params.copyrightOptions.copyrightLink }}">{{ $.Site.Params.copyrightOptions.copyrightLinkText }}</a>{{ $rightString | markdownify }}
                    {{ end }}
                {{ else }}
                    {{ with $.Site.Copyright }}{{ replace . "{year}" now.Year | markdownify}}{{ end }}
                {{ end }}
            </p>
        {{ end }}

        {{ if $.Param "showPoweredBy" }}
            <p class="caption">Powered by <a href="https://gohugo.io/" target="_blank" rel="noreferrer">Hugo</a> and the <a href="https://github.com/zzossig/hugo-theme-zzo" target="_blank" rel="noreferrer">Zzo theme</a></p>
        {{ end }}
        
    </div> 
</footer>